package com.ylr.common.service.impl;

import com.alicp.jetcache.anno.CacheType;
import com.alicp.jetcache.anno.Cached;
import com.ylr.common.model.Weblog.WebLog;
import com.ylr.common.service.TestService;
import org.springframework.stereotype.Service;

/**
 * @ClassName TestServiceImpl
 * @Description TODO
 * @Author 11
 * @Date 2021/4/23 11:56
 * @Version 1.0
 */


@Service
public class TestServiceImpl implements TestService {
//    @Override
    @Cached(name = "com.ylr.common.service.impl.TestServiceImpl:",key = "#username",cacheType = CacheType.BOTH)
    public WebLog get(String username) {
        WebLog webLog = new WebLog();
        webLog.setUsername(username);
        webLog.setResult("ok!");

        return webLog;
    }
}
